# gcc -mcpu=440fp -O2 -c tlb.S

# read_tlb_entry
# r3: entry index
# r4: address to dump data (W0, W1, W2, STID)
   .globl read_tlb_entry
   .align 4
read_tlb_entry:
   tlbre 5, 3, 0
   stw 5,0(4)
   mfspr 6, 0x3b2 # Read MMUCR
   stw 6, 12(4)
   tlbre 5, 3, 1
   stw 5, 4(4)
   tlbre 5, 3, 2
   stw 5, 8(4)
   blr
